package com.jianzhile.jobs.activities.mine;

import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.ActionBar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.widget.ImageButton;

import com.jianzhile.jobs.R;

import butterknife.Bind;
import butterknife.ButterKnife;

/**
 * Create by terry on 16/3/3
 * 公司详情
 */
public class CompanyDetailActivity extends AppCompatActivity implements View.OnClickListener{

    @Bind(R.id.content_company_detail_add_ib)
    public ImageButton addCompanyIb;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_company_detail);
        ButterKnife.bind(this);

        Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
        setSupportActionBar(toolbar);

        final ActionBar ab = getSupportActionBar();
        ab.setElevation(0);

        ab.setDisplayHomeAsUpEnabled(true);
        ab.setDefaultDisplayHomeAsUpEnabled(true);
        toolbar.setNavigationOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                CompanyDetailActivity.this.finish();
            }
        });
        ab.setTitle("");

        initListener();
    }

    private void initListener() {
        addCompanyIb.setOnClickListener(this);
    }


    @Override
    public void onClick(View v) {
         switch (v.getId()){
             case R.id.content_company_detail_add_ib:
                 Intent intent = new Intent(CompanyDetailActivity.this, PerfectCompanyInfoActivity.class);
                 startActivity(intent);
                 break;
         }
    }
}
